package com.woniu.order.mapper;

import com.woniu.order.pojo.Coupons;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Update;

/**
 * <p>
 * 优惠券表 Mapper 接口
 * </p>
 *
 * @author LiFangyu
 * @since 2023-02-15
 */
public interface CouponsMapper extends BaseMapper<Coupons> {

    boolean queryCouponsType(Long id);


    @Update("update t_coupons set stock = 0 where id=#{id}")
    boolean updateCouponsById(Integer id);

}
